package com.marktotop.learnone;

import com.alibaba.druid.pool.DruidDataSource;
import com.marktotop.learnone.service.UserService;
import org.springframework.beans.factory.xml.XmlBeanFactory;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;

/**
 * @author WXLD
 * @data 2021/4/18 - 10:20
 */
public class Main {

    public static void main(String[] args) {

        ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext("applicationContext.xml");
        /*UserService userService = (UserService) context.getBean("userService");
        userService.save();*/

        DruidDataSource dataSource = (DruidDataSource) context.getBean("dataSource");
        System.out.println(dataSource);


    }
}
